package com.shop.entity;

import java.util.Objects;

//���������
public class OrderDetail {
    private int od_id;  //���������id
    private int o_id;   //����id�����2��
    private int gd_id;  //��Ʒ�����
    private int s_id;   //�̼�id
    private int od_status; //��������״̬

    public OrderDetail(int od_id, int o_id, int gd_id, int s_id, int od_status) {

        this.od_id = od_id;
        this.o_id = o_id;
        this.gd_id = gd_id;
        this.s_id = s_id;
        this.od_status = od_status;
    }

    public OrderDetail() {
    }

    public int getOd_id() {
        return od_id;
    }

    public void setOd_id(int od_id) {
        this.od_id = od_id;
    }

    public int getO_id() {
        return o_id;
    }

    public void setO_id(int o_id) {
        this.o_id = o_id;
    }

    public int getGd_id() {
        return gd_id;
    }

    public void setGd_id(int gd_id) {
        this.gd_id = gd_id;
    }

    public int getS_id() {
        return s_id;
    }

    public void setS_id(int s_id) {
        this.s_id = s_id;
    }

    public int getOd_status() {
        return od_status;
    }

    public void setOd_status(int od_status) {
        this.od_status = od_status;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        OrderDetail that = (OrderDetail) o;
        return od_id == that.od_id &&
                o_id == that.o_id &&
                gd_id == that.gd_id &&
                s_id == that.s_id &&
                od_status == that.od_status;
    }

    @Override
    public int hashCode() {
        return Objects.hash(od_id, o_id, gd_id, s_id, od_status);
    }

    @Override
    public String toString() {
        return "OrderDetail{" +
                "od_id=" + od_id +
                ", o_id=" + o_id +
                ", gd_id=" + gd_id +
                ", s_id=" + s_id +
                ", od_status=" + od_status +
                '}';
    }
}
